<?php

/**
 * Notice form base class.
 *
 * @package    stock
 * @subpackage form
 * @author     Your name here
 */
class BaseNoticeForm extends BaseFormPropel
{
  public function setup()
  {
    $this->setWidgets(array(
      'id'       => new sfWidgetFormInputHidden(),
      'content'  => new sfWidgetFormInput(),
      'datetime' => new sfWidgetFormDateTime(),
    ));

    $this->setValidators(array(
      'id'       => new sfValidatorPropelChoice(array('model' => 'Notice', 'column' => 'id', 'required' => false)),
      'content'  => new sfValidatorString(array('max_length' => 255)),
      'datetime' => new sfValidatorDateTime(),
    ));

    $this->widgetSchema->setNameFormat('notice[%s]');

    $this->errorSchema = new sfValidatorErrorSchema($this->validatorSchema);

    parent::setup();
  }

  public function getModelName()
  {
    return 'Notice';
  }


}
